	<form id="form" action="<?php echo site_url(array('perfil', 'modificar'));?>" method="post">
			<table class="form-table">
				<tr>
		   			<td><label for="documento">CI *</label></td>
		    		<td><input id="documento" name="documento" type="number" size="25" maxlength="8" value="<?php echo $usuario['documento']?>" class="validate[required, custom[number], minSize[8]]"></input></td>
				</tr>
		  		<tr>
		   			<td><label for="nombres">Nombre *</label></td>
		   			<td><input name="nombres" type="text" size="25" maxlength="45" value="<?php echo $usuario['nombres']?>" class="validate[required]"></input></td>
				<tr>
		   			<td><label for="apellidos">Apellido *</label></td>
		    		<td><input name="apellidos" type="text" size="25" maxlength="45" value="<?php echo $usuario['apellidos'] ?>" class="validate[required]"></input></td>
				</tr>

				<tr>
		   			<td><label for="email">Email *</label></td>
		    		<td><input name="email" type="text" size="25" maxlength="45" value="<?php echo $usuario['email']?>" class="validate[required,custom[email]]"></input></td>
				</tr>
				<tr>
		   			<td><label for="password">Password *</label></td>
		    		<td><input name="password" type="password" size="25" maxlength="45" value="<?php echo $usuario['password']?>" class="validate[required,minSize[6]]"></input></td>
		    		<td> <a id="editar-pass" href="#">Editar</a></td>
				</tr>
				<tr>
					<td><label for="tipo">Tipo Usuario</label></td>
					<td><input name="tipo" type="text" size="25" maxlength="45"  readonly="readonly" value="<?php echo $usuario['tipo']?>" class="validate[required]"></input></td>
				</tr>								
		   		<tr>
		   			<td><label for="pais_fk">Pais</label></td>
		   			<td>
						<select name="pais_fk" style="width: 200px;">
							<option></option>
							<?php foreach ($paises as $pais):?>
							<option <?php if ($pais['id'] == $usuario['pais_fk']) echo 'selected="selected"';?> value=<?php echo $pais['id'];?>><?php echo $pais['nombre'];?></option>
							<?php endforeach;?>
						</select>
					</td>			    		
				</tr>
		   		<tr>
		   			<td><label for="departamento_fk">Departamento</label></td>
		   			<td>
						<select name="departamento_fk" style="width: 200px;">
							<option></option>
							<?php foreach ($departamentos as $departamento):?>
							<option <?php if ($departamento['id'] == $usuario['departamento_fk']) echo 'selected="selected"';?> value=<?php echo $departamento['id'];?>><?php echo $departamento['nombre'];?></option>
							<?php  endforeach;?>
						</select>
					</td>		    		
				</tr>
		   		<tr>
		   			<td><label for="barrio">Barrio</label></td>
		    		<td><input name="barrio" type="text" size="25" value="<?php echo $usuario['barrio']?>"></input></td>
				</tr>															
		   		<tr>
		   			<td><label for="direccion">Direccion</label></td>
		    		<td><input name="direccion" type="text" size="25" value="<?php echo $usuario['direccion']?>" class="validate[required]"></input></td>
				</tr>
		   		<tr>
		   			<td><label for="celular">Celular / Telefono </label></td>
		    		<td><input name="celular" type="number" size="25" value="<?php echo $usuario['celular']?>" class="validate[required, custom[phone]]"></input></td>
				</tr>
			</table>
			<input name="coordenadas" type="hidden" value="<?php echo $usuario['coordenadas']?>">
			<input type="submit" value="Salvar" style="float: right;" >
			
			<!-- ver para colocar en form aparte. resovler logica. ver tema de jquery actual-->
			<div id="dialog-form-pass" style="display: none;">
				<table>
					<tr>
						<td> <label for="pass_actual" >Password actual</label></td>
						<td> <input name="pass_actual" type="password" size="25" maxlength="45"> </td>
					</tr>
					
					<tr>
						<td> <label for="pass_nuevo">Nuevo Password</label></td>
						<td> <input name="pass_nuevo" type="password" size="25" maxlength="45"> </td>
					</tr>
					
					<tr>
						<td> <label for="pass_rep_nuevo">Repertir Password</label></td>
						<td> <input name="pass_rep_nuevo" type="password" size="25" maxlength="45"> </td>
					</tr>
				</table>
			</div>
	</form>

	 <script type="text/javascript">
	 	//abrir pop-up para edicion de password
		$("#editar-pass").click(function(){
			 abrirPasswordForm();
		});
 	</script> 